<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<style>
    .pic-list img {
        width: 320px;
        height: 160px;
    }
    
    .big-pic {
        position: absolute;
    }
    
    .big-pic img {
        width: 640px;
        height: 320px;
    }
</style>

<body>
    <div class="pic-list">
        <img src="images/1.png" alt="">
        <img src="images/2.png" alt="">
        <img src="images/3.png" alt="">
    </div>
    <div class="big-pic"></div>
    <script>
        var ImgList = document.querySelectorAll('.pic-list img');
        var Big_Pic = document.querySelector('.big-pic');
        var Pic_List = document.querySelector('.pic-list');
        for (var i in ImgList) {
            ImgList[i].onmouseenter = function() {
                let img = `
                    <img src='${this.src}'>
                `
                Big_Pic.innerHTML = img;
            }
            ImgList[i].onmouseleave = function() {
                Big_Pic.innerHTML = '';
            }
        }
        Pic_List.onmousemove = function(e) {
            var x = e.clientX;
            var y = e.clientY;
            Big_Pic.style.top = y + 10 + 'px';
            Big_Pic.style.left = x + 10 + 'px';
        }
    </script>
</body>

</html>